import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, browserHistory } from 'react-router'

import Index from './index'
import List from './components/list'
import Details from './components/Details'

export default class Root extends React.Component{
    render() {
        return(
            // browserHistory hashHistory
            <Router history={browserHistory}>
                <Route component={Index} path="/">
                    <Route component={Details} path="/details"></Route>
                </Route>
                <Route component={List} path="list/:id"></Route>
            </Router>
        )
    }
}


ReactDOM.render( <Root/>,document.getElementById('example') );